package com.smalljj.service;

import com.smalljj.bean.User;
import com.smalljj.bean.UserKey;

public interface UserService {

    /**
     * 保存用户
     * @param user
     */
    public boolean insert(User user) throws Exception;

    /**
     * 更新用户
     * @param user
     */
    public boolean updateUser(User user)throws Exception;
    
    /**
     * 根据key查找用户
     * @param id
     * @return
     */
    public User findByKey( UserKey keyBean )throws Exception;

    /**
     * 根据userName查找用户
     * @param id
     * @return
     */
    public User findUserByName(String userName)throws Exception;
    
}
